import unittest
from UserTestCase import UserTestCase
from UserTestCase2 import UserTestCase2


class VideoTestCase(unittest.TestCase):
    def setUp(self):
        print("set up 开始")

    def tearDown(self):
        print("tearDown 执行结束")

    def testCase1(self):
        print("VideoTestCase test case1")

    def testCase2(self):
        print("VideoTestCase test case2")
        self.assertEqual(1, 1)

    def testCase3(self):
        print("VideoTestCase test case3")
        self.assertEqual(1, 2)


if __name__ == '__main__':
    # 构造测试套件
    suite = unittest.TestSuite()

    # 实例化 loader
    loader = unittest.TestLoader()

    # 加载 UserTestCase 下的全部用例
    suite.addTests(loader.loadTestsFromTestCase(UserTestCase))

    # 加载 UserTestCase2 下的全部用例
    suite.addTests(loader.loadTestsFromTestCase(UserTestCase2))

    # 加载 VideoTestCase 下的全部用例
    # suite.addTests(loader.loadTestsFromTestCase(VideoTestCase))

    runner = unittest.TextTestRunner(verbosity=2)

    runner.run(suite)
